import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import tailwindcss from '@tailwindcss/vite'
import path from 'path'
import { createSvgIconsPlugin } from 'vite-plugin-svg-icons'
export default defineConfig({
  plugins: [
    vue(),
    tailwindcss(),
    createSvgIconsPlugin({
      iconDirs: [path.resolve(process.cwd(), 'src/assets/icons')], // SVG 存放目录
      symbolId: 'icon-[dir]-[name]', // 命名规则
    }),

  ],
  server: {
    proxy: {
      '/api/': {
        target: 'http://192.168.1.105:8280',
        changeOrigin: true
      }
    }
  }
})
